package com.sell.exception;


import com.sell.enums.SellExceptionEnum;
import lombok.Getter;

/**
 * @author: lichujun
 * @date: 2018-08-15
 */
@Getter
public class SellException extends RuntimeException {
    private Integer code;

    public SellException(SellExceptionEnum resultEnum) {
        super(resultEnum.getMsg());
        this.code = resultEnum.getCode();
    }

    public SellException(Integer code, String message) {
        super(message);
        this.code = code;
    }
}
